package com.ruoyi.course.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.course.mapper.course_qualityMapper;
import com.ruoyi.course.domain.course_quality;
import com.ruoyi.course.service.Icourse_qualityService;

/**
 * courseService业务层处理
 * 
 * @author ruoyi
 * @date 2025-05-23
 */
@Service
public class course_qualityServiceImpl implements Icourse_qualityService 
{
    @Autowired
    private course_qualityMapper course_qualityMapper;

    /**
     * 查询course
     * 
     * @param courseId course主键
     * @return course
     */
    @Override
    public course_quality selectcourse_qualityByCourseId(Long courseId)
    {
        return course_qualityMapper.selectcourse_qualityByCourseId(courseId);
    }

    /**
     * 查询course列表
     * 
     * @param course_quality course
     * @return course
     */
    @Override
    public List<course_quality> selectcourse_qualityList(course_quality course_quality)
    {
        return course_qualityMapper.selectcourse_qualityList(course_quality);
    }

    /**
     * 新增course
     * 
     * @param course_quality course
     * @return 结果
     */
    @Override
    public int insertcourse_quality(course_quality course_quality)
    {
        course_quality.setCreateTime(DateUtils.getNowDate());
        return course_qualityMapper.insertcourse_quality(course_quality);
    }

    /**
     * 修改course
     * 
     * @param course_quality course
     * @return 结果
     */
    @Override
    public int updatecourse_quality(course_quality course_quality)
    {
        course_quality.setUpdateTime(DateUtils.getNowDate());
        return course_qualityMapper.updatecourse_quality(course_quality);
    }

    /**
     * 批量删除course
     * 
     * @param courseIds 需要删除的course主键
     * @return 结果
     */
    @Override
    public int deletecourse_qualityByCourseIds(Long[] courseIds)
    {
        return course_qualityMapper.deletecourse_qualityByCourseIds(courseIds);
    }

    /**
     * 删除course信息
     * 
     * @param courseId course主键
     * @return 结果
     */
    @Override
    public int deletecourse_qualityByCourseId(Long courseId)
    {
        return course_qualityMapper.deletecourse_qualityByCourseId(courseId);
    }
}
